\hypertarget{xlabelstring_8h_source}{}\doxysection{xlabelstring.\+h}
\mbox{\hyperlink{xlabelstring_8h}{浏览该文件的文档.}}
\begin{DoxyCode}{0}
\DoxyCodeLine{1 \textcolor{preprocessor}{\#ifndef XLABELSTRING\_H}}
\DoxyCodeLine{2 \textcolor{preprocessor}{\#define XLABELSTRING\_H}}
\DoxyCodeLine{3 }
\DoxyCodeLine{4 \textcolor{preprocessor}{\#include <QLabel>}}
\DoxyCodeLine{5 \textcolor{preprocessor}{\#include <QPainter>}}
\DoxyCodeLine{6 \textcolor{preprocessor}{\#include <QMouseEvent>}}
\DoxyCodeLine{7 \textcolor{preprocessor}{\#include <QApplication>}}
\DoxyCodeLine{8 \textcolor{preprocessor}{\#include <QDebug>}}
\DoxyCodeLine{9 }
\DoxyCodeLine{10 \textcolor{preprocessor}{\#include "{}\mbox{\hyperlink{xnamespace_8h}{xnamespace.h}}"{}}}
\DoxyCodeLine{11 \textcolor{preprocessor}{\#pragma execution\_character\_set("{}utf-\/8"{}})}
\DoxyCodeLine{12 }
\DoxyCodeLine{13 QT\_BEGIN\_NAMESPACE}
\DoxyCodeLine{14 }
\DoxyCodeLine{15 \textcolor{keyword}{class }\mbox{\hyperlink{class_x_label_string_private}{XLabelStringPrivate}};}
\DoxyCodeLine{16 \textcolor{keyword}{class }\mbox{\hyperlink{class_x_label_string}{XLabelString}} : \textcolor{keyword}{public} QLabel}
\DoxyCodeLine{17 \{}
\DoxyCodeLine{18     Q\_OBJECT}
\DoxyCodeLine{19 }
\DoxyCodeLine{20     Q\_PROPERTY(QColor \mbox{\hyperlink{class_x_label_string_a9485a23d271a497cf04cad502b7483c2}{borderColor}} READ \mbox{\hyperlink{class_x_label_string_aa22668ad0c115a075f9d646c7ee612e6}{getBorderColor}} WRITE \mbox{\hyperlink{class_x_label_string_a5011679422e0fcbbbf65f327258bf5c2}{setBorderColor}})}
\DoxyCodeLine{21     Q\_PROPERTY(\textcolor{keywordtype}{int} \mbox{\hyperlink{class_x_label_string_a11d12f45213825836fe25a9aec346b25}{borderWidth}} READ \mbox{\hyperlink{class_x_label_string_ae1279425b30710fbca805f5ff2afdc7d}{getBorderWidth}} WRITE \mbox{\hyperlink{class_x_label_string_ad8f3377f17f7337ae472b65c78881d11}{setBorderWidth}})}
\DoxyCodeLine{22     Q\_PROPERTY(\textcolor{keywordtype}{int} \mbox{\hyperlink{class_x_label_string_aed6fcc0876a2ed0edb0b2d07d0481c36}{borderRadius}} READ \mbox{\hyperlink{class_x_label_string_ab186d2cb8e6aa4182c0999243f81ccf8}{getBorderRadius}} WRITE \mbox{\hyperlink{class_x_label_string_afa03bac2f2305dc07db05d713bb737c2}{setBorderRadius}})}
\DoxyCodeLine{23     Q\_PROPERTY(QColor \mbox{\hyperlink{class_x_label_string_a346f576ed2ee8c952a99d0f7a293cf35}{labelBgColor}} READ \mbox{\hyperlink{class_x_label_string_a077cefe7cea788864f480e58a99a6606}{getLabelBgColor}} WRITE \mbox{\hyperlink{class_x_label_string_a3a4ef047ec0cc8fa9c655f0e63d8a234}{setLabelBgColor}})}
\DoxyCodeLine{24 }
\DoxyCodeLine{25     Q\_PROPERTY(QString \mbox{\hyperlink{class_x_label_string_af969864e0d7e9e85000be1258c6b6b4e}{displayString}} READ \mbox{\hyperlink{class_x_label_string_ac4e457122baca31810c7509dab57f50e}{getDisplayString}} WRITE \mbox{\hyperlink{class_x_label_string_a7ad3e44576fc2b44a209c4e060c9e8b4}{setDisplayString}})}
\DoxyCodeLine{26     Q\_PROPERTY(\textcolor{keywordtype}{bool} \mbox{\hyperlink{class_x_label_string_a9b846f063f795310afd4cc77bdd50cd5}{displayEnable}} READ \mbox{\hyperlink{class_x_label_string_abdcc3f1334883b11570268e8201a1ab9}{getDisplayEnable}} WRITE \mbox{\hyperlink{class_x_label_string_a5fdaa336f2795c52e4787c0a795f0296}{setDisplayEnable}})}
\DoxyCodeLine{27     Q\_PROPERTY(\textcolor{keywordtype}{bool} \mbox{\hyperlink{class_x_label_string_a475e8e00cd7d7a9dd2be842994038be7}{displayDefault}} READ \mbox{\hyperlink{class_x_label_string_aff21e4570135022131e59b9d2451567d}{getDisplayDefault}} WRITE \mbox{\hyperlink{class_x_label_string_a4639456e6ab91f2f0c2096860847ecb3}{setDisplayDefault}})}
\DoxyCodeLine{28 }
\DoxyCodeLine{29 \textcolor{keyword}{public}:}
\DoxyCodeLine{30     \textcolor{keyword}{explicit} \mbox{\hyperlink{class_x_label_string_a9b7b6cb2c0f7c080e53aa0d1a435a549}{XLabelString}}(QWidget *parent = \textcolor{keyword}{nullptr}, Qt::WindowFlags f=Qt::WindowFlags());}
\DoxyCodeLine{31     \mbox{\hyperlink{class_x_label_string_aeffe53f5a8603649bddaa768d0388561}{\string~XLabelString}}();}
\DoxyCodeLine{32 }
\DoxyCodeLine{33     \textcolor{comment}{/* Property Interface */}}
\DoxyCodeLine{34     QColor \mbox{\hyperlink{class_x_label_string_aa22668ad0c115a075f9d646c7ee612e6}{getBorderColor}}() \textcolor{keyword}{const};}
\DoxyCodeLine{35     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a5011679422e0fcbbbf65f327258bf5c2}{setBorderColor}}(\textcolor{keyword}{const} QColor \&color);}
\DoxyCodeLine{36 }
\DoxyCodeLine{37     \textcolor{keywordtype}{int} \mbox{\hyperlink{class_x_label_string_ae1279425b30710fbca805f5ff2afdc7d}{getBorderWidth}}() \textcolor{keyword}{const};}
\DoxyCodeLine{38     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_ad8f3377f17f7337ae472b65c78881d11}{setBorderWidth}}(\textcolor{keywordtype}{int});}
\DoxyCodeLine{39 }
\DoxyCodeLine{40     \textcolor{keywordtype}{int} \mbox{\hyperlink{class_x_label_string_ab186d2cb8e6aa4182c0999243f81ccf8}{getBorderRadius}}() \textcolor{keyword}{const};}
\DoxyCodeLine{41     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_afa03bac2f2305dc07db05d713bb737c2}{setBorderRadius}}(\textcolor{keywordtype}{int});}
\DoxyCodeLine{42 }
\DoxyCodeLine{43     QColor \mbox{\hyperlink{class_x_label_string_a077cefe7cea788864f480e58a99a6606}{getLabelBgColor}}() \textcolor{keyword}{const};}
\DoxyCodeLine{44     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a3a4ef047ec0cc8fa9c655f0e63d8a234}{setLabelBgColor}}(\textcolor{keyword}{const} QColor \&color);}
\DoxyCodeLine{45 }
\DoxyCodeLine{46     QString \mbox{\hyperlink{class_x_label_string_ac4e457122baca31810c7509dab57f50e}{getDisplayString}}() \textcolor{keyword}{const};}
\DoxyCodeLine{47     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a7ad3e44576fc2b44a209c4e060c9e8b4}{setDisplayString}}(QString str);}
\DoxyCodeLine{48 }
\DoxyCodeLine{49     \textcolor{keywordtype}{bool} \mbox{\hyperlink{class_x_label_string_abdcc3f1334883b11570268e8201a1ab9}{getDisplayEnable}}() \textcolor{keyword}{const};}
\DoxyCodeLine{50     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a5fdaa336f2795c52e4787c0a795f0296}{setDisplayEnable}}(\textcolor{keywordtype}{bool});}
\DoxyCodeLine{51 }
\DoxyCodeLine{52     \textcolor{keywordtype}{bool} \mbox{\hyperlink{class_x_label_string_aff21e4570135022131e59b9d2451567d}{getDisplayDefault}}() \textcolor{keyword}{const};}
\DoxyCodeLine{53     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a4639456e6ab91f2f0c2096860847ecb3}{setDisplayDefault}}(\textcolor{keywordtype}{bool});}
\DoxyCodeLine{54 }
\DoxyCodeLine{55 \textcolor{keyword}{protected}:}
\DoxyCodeLine{56     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a979b339f6dcb9113966c302b099d07e0}{paintEvent}}(QPaintEvent *ev) \textcolor{keyword}{override};}
\DoxyCodeLine{57     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a2c61e3ff203537bbc99355b4259187bf}{drawBorder}}(QPainter *painter);}
\DoxyCodeLine{58     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_aee9734293432ec6049b0908194524f6c}{drawBg}}(QPainter *painter);}
\DoxyCodeLine{59 }
\DoxyCodeLine{60     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a60f4be946f3dd16718a08d797d06b8b0}{enterEvent}}(QEvent *ev) \textcolor{keyword}{override};}
\DoxyCodeLine{61     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a76b3f68d713df13cb72c850bae585095}{leaveEvent}}(QEvent *ev) \textcolor{keyword}{override};}
\DoxyCodeLine{62     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a88960aa72167c204f71d5fd9a4490414}{mousePressEvent}}(QMouseEvent *ev) \textcolor{keyword}{override};}
\DoxyCodeLine{63     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_aa45be1b6946ff78e36d51ec715b52b56}{mouseReleaseEvent}}(QMouseEvent *ev) \textcolor{keyword}{override};}
\DoxyCodeLine{64     \textcolor{keywordtype}{void} \mbox{\hyperlink{class_x_label_string_a0e0ca47293c0d18750c9e9ed74a07782}{mouseMoveEvent}}(QMouseEvent *ev) \textcolor{keyword}{override};}
\DoxyCodeLine{65 }
\DoxyCodeLine{66 \textcolor{keyword}{private}:}
\DoxyCodeLine{67     Q\_DISABLE\_COPY(\mbox{\hyperlink{class_x_label_string}{XLabelString}})}
\DoxyCodeLine{68     \mbox{\hyperlink{class_x_label_string_private}{XLabelStringPrivate}} *\mbox{\hyperlink{class_x_label_string_a673024d4b262cca57f8e5a965db69aca}{d}};}
\DoxyCodeLine{69 \};}
\DoxyCodeLine{70 }
\DoxyCodeLine{71 QT\_END\_NAMESPACE}
\DoxyCodeLine{72 }
\DoxyCodeLine{73 \textcolor{preprocessor}{\#endif }\textcolor{comment}{// XLABELSTRING\_H}}

\end{DoxyCode}
